import Header from './Header.vue'
import Footer from './Footer.vue'
//定义数组，将组件填入
const components = [Header, Footer]
export default {
  install (app) {
    //遍历components：利用数组的forEach循环，注册全局组件
    components.forEach(item=>{
      app.component(item.name, item)
    })
  }
}